import request from "./index";

/**
 * 上传文章配图
 * @param article_pic
 * @returns {*}
 */
export function uploadArticlePic(article_pic) {
  return request({
    url: "/upload/article_pic",
    method: "POST",
    data: article_pic,
    processData: false,
    contentType: false
  })
}

/**
 * 上传用户壁纸
 * @param wall
 * @returns {*}
 */
export function uploadWall(wall) {
  return request({
    url: "/upload/wall",
    method: "POST",
    data: wall,
    processData: false,
    contentType: false
  })
}

/**
 * 上传用户头像
 * @param avatar
 * @returns {*}
 */
export function uploadAvatar(avatar) {
  return request({
    url: "/upload/avatar",
    method: "POST",
    data: avatar,
    processData: false,
    contentType: false
  })
}

/**
 * 上传用户背景
 * @param cover
 * @returns {*}
 */
export function uploadCover(cover) {
  return request({
    url: "/upload/cover",
    method: "POST",
    data: cover,
    processData: false,
    contentType: false
  })
}
